﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Threading.Tasks;

using MongoDB.Bson;
using MongoDB.Bson.IO;

using RexToy.WebService;

using Monitor.Core;
using Monitor.Core.Entity;

namespace Monitor.Web.Dashboard
{
    [WebService("Dashboard")]
    public class Dashboard
    {
        [WebFunction("OverAll")]
        public List<SensorResult> OverAll()
        {
            DataReader r = new DataReader();
            return r.ReadLatest().ToList();
        }
    }
}
